import React, { useState } from "react";
import { Toast, NavBar, Search, Swiper, Image } from "react-vant";
import { Contact, BulbO } from "@react-vant/icons";
import { useNavigate } from "react-router-dom";
import './index.css'
const Index: React.FC = () => {
  const navigate = useNavigate();
  const cjbz = () => {
    console.log("常见病症");
    navigate("/commonsymptoms");
  };
  const cyyw = () => {
    console.log("常见药物");
    navigate("/commondrugs");
  };
  return (
    <div>
      <div className="TopKnowledgeEncyclopedia">
        <div>知识宝典</div>
      </div>
      <div className="BtnKnowledgeEncyclopedia">
        <div className="LeftBtnKnowledgeEncyclopedia" onClick={() => cjbz()}>
          <div className="TLeftBtnKnowledgeEncyclopedia">
            <span>常见病症</span>
          </div>
          <div className="BLeftBtnKnowledgeEncyclopedia">
            <img src="https://pic1.zhimg.com/80/v2-04d1280817ab639fb3e5c9490370728c_720w.webp" />
          </div>
        </div>
        <div className="RightBtnKnowledgeEncyclopedia" onClick={() => cyyw()}>
          <div className="TRightBtnKnowledgeEncyclopedia">
            <span>常用药物</span>
          </div>
          <div className="BRightBtnKnowledgeEncyclopedia">
            <img src="http://mms1.baidu.com/it/u=367603362,630570393&fm=253&app=138&f=PNG?w=658&h=494" />
          </div>
        </div>
      </div>
    </div>
  );
};
export default Index;
